package com.guigusuqi.payment.service;

import com.guigusuqi.commonutils.vo.Result;
import com.guigusuqi.payment.entity.UserOrderRegistration;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.web.bind.annotation.RequestBody;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.Map;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author suqi
 * @since 2022-04-22
 */
public interface UserOrderRegistrationService extends IService<UserOrderRegistration>
{
    /**
     * JSAPI预支付
     * @param registrationId
     * @return
     */
    Result JSAPIPreparePay(String registrationId) throws Exception;

    /**
     * 支付回调
     * @param body
     * @param request
     * @return
     */
    Result payNotify(@RequestBody Map body, HttpServletRequest request);
}
